home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus 1995 #5 & #6
/
Amiga Plus CD - 1995 - No. 5 and 6.iso
/
pd
/
serien
/
purity
/
nr.10
/
demo
/
sparx.i
/
.spark11.i
< prev
next >
Wrap
Text File
|
1995-04-19
|
1KB
|
63 lines
Procedure Spark11;
Const
max4lines = 40;
Type
Sp1lines = Array[1..max4lines] of line;
Sp1LinesPtr = ^Sp1Lines;
Var
arr : Sp1LinesPtr;
cnt1,
cnt2,
cnt3,
CCNT,
add1,
add2,
add3,
actualline : Short;
Begin
New(arr);
ActualLine := 1;
cnt1 := 546; add1 := 7; { x1 }
cnt2 := 3; add2 := 3; { y1 }
cnt3 := 197; add3 := 13; { x2 }
CCNT := 2; { color }
Repeat
EraseLine( Adr(arr^[actualline]) );
With arr^[actualline] do begin
x1 := 170 + XSin^[cnt1] * 6 DIV 5; { +- max.120 }
y1 := 110 + Xsin^[cnt2] * 11 DIV 10; { +- max.110 }
x2 := 160 + XSin^[cnt3] * 7 DIV 5; { +- max.140 }
y2 := 255;
end;
cnt1 := cnt1 + add1;
if cnt1>627 then cnt1:= cnt1-628;
cnt2 := cnt2 + add2;
if cnt2>627 then cnt2:= cnt2-628;
cnt3 := cnt3 + add3;
if cnt3>627 then cnt3:= cnt3-628;
DrawLine( Adr(arr^[actualline]), CCNT );
inc( CCNT );
If CCNT > maxColors then CCNT := 2;
inc( actualline );
If actualline >= max4lines then actualline := 1;
Until LeftMouseButton;
Ciao;
Dispose(arr);
SetSColors(Adr(Def_Colors));
End;